/*问题类别类*/
class Category {
	protected int id;
	protected Long categoryCode;
	protected String name;
	protected String description;
	protected Category parentCategory;
	protected Set<Category> childCategories;
	protected Set<Question> questions;

	public Category() {
		
	}

	/** 在此类别下添加一个子类别如果此子类别原来已经有父类别的话,从原来的父类别所有的子类别集合中删除 */
	public static void addChildCategory (Category childCategory) {
		
	}

}

/*问题的回答类*/
class Anwser {
	protected int questionId;
	protected String content;
	protected Timestamp answerTime;

	public Anwser() {
		
	}

}

/*问题实体类,注意一个问题可以属性多个类别,同时有多个回答.*/
class Question {
	protected int id;
	protected String title;
	protected String content;
	protected Timestamp createTime;
	protected viewCount int;
	protected Set<Category> categories;
	protected Set<Answer> answers;

	public Question() {
		
	}

	/** 添加此问题的类别 */
	public static void addCategory (Category category) {
		
	}

}

